package com.example.healthmanagement.dao;

import com.example.healthmanagement.entity.CookBook;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface CookBookRepository extends JpaRepository<CookBook, Long> {

    List<CookBook> getCookBooksByDeleted(Boolean deleted);
    List<CookBook> getCookBooksByDeletedAndBookName(boolean deleted, String bookName);

    CookBook findCookBookByIdAndDeleted(int id, boolean deleted);

    List<CookBook> findCookBooksByDeletedAndBookNameContaining(boolean deleted, String key);
}
